Skip to content

feat(userflags): tip presets for preferred currency#1115

Merged
bmc08gt merged 2 commits into
code/cashfrom
feat/flipcash-tip-presets
Jul 22, 2026
Merged

feat(userflags): tip presets for preferred currency#1115
bmc08gt merged 2 commits into
code/cashfrom
feat/flipcash-tip-presets

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Jul 22, 2026

Copy link
Copy Markdown
Collaborator

Summary

Syncs the flipcash protos and wires the new UserFlags.tip_presets field through the domain layer, surfacing it read-only in the flags debug screen.

UserFlags gained field 15 repeated TipPresets tip_presets (each: a common.v1.Region currency-code + minimum/low/medium/high amounts). No RPC changes.

Changes

chore(protos) — regenerated flipcash protos (TipPresets message + UserFlags.tip_presets).

feat(userflags)

  • TipPresets domain model + tipPresets: List<TipPresets> on UserFlags (defaults empty) + mapper
  • CachedTipPresets serializable mirror in UserFlagsCoordinator so presets survive the persisted flags cache
  • ResolvedUserFlags carries tipPresets read-only (no debug override — a repeated struct does not fit the Field editor)
  • Flags debug screen renders only the preferred currency's preset (via PreferredCurrencyController), formatted as Fiat values; falls back to USD if the currency cannot be resolved

Testing

  • UserFlagsMapperTest: 2 new tests (maps presets; empty by default) — passing
  • :definitions:flipcash:models, :services:flipcash, :apps:flipcash:shared:userflags, :apps:flipcash:features:userflags, and full :apps:flipcash:app:assembleDebug all build

@github-actions github-actions Bot added area: network gRPC, connectivity, API, exchange rates type: feature New functionality labels Jul 22, 2026
bmc08gt added 2 commits July 21, 2026 20:39
Sync flipcash protos: UserFlags gains field 15 `repeated TipPresets
tip_presets`, plus a new `TipPresets` message (region + minimum/low/
medium/high tip amounts per currency).
Map the new UserFlags.tip_presets proto field through the domain layer
and expose it read-only in the flags debug screen.

- TipPresets domain model + field on UserFlags (Default empty) + mapper
- CachedTipPresets serializable mirror in UserFlagsCoordinator so presets
  survive the persisted flags cache
- ResolvedUserFlags carries tipPresets read-only (no override)
- Flags debug screen renders only the preferred currency's preset,
  formatted as Fiat values (falls back to USD if unresolved)
@bmc08gt
bmc08gt force-pushed the feat/flipcash-tip-presets branch from a992795 to c1e0637 Compare July 22, 2026 00:39
@bmc08gt
bmc08gt merged commit bec705d into code/cash Jul 22, 2026
3 checks passed
@bmc08gt
bmc08gt deleted the feat/flipcash-tip-presets branch July 22, 2026 00:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: network gRPC, connectivity, API, exchange rates type: feature New functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant